<!--  Ofri Keidar 302933981 group 05 -->

<%@page import="view.WebCommons"%>
<%@page import="controller.EmployeeController"%>
<%@page import="builder.ControllerBuilder"%>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
	pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<%
	// get employee controller
	ControllerBuilder sysBuilder = (ControllerBuilder) session.getAttribute(WebCommons.BUILDER);
	EmployeeController controller = sysBuilder.getEmployeeController();

	// keep controller in session
	session.setAttribute(WebCommons.CONTROLLER, controller);

	//keep main-menu page in session
	session.setAttribute(WebCommons.MAIN_MANU, "EmployeeMenu.jsp");
	
	// remove from session number of last-to-be-handled client
	session.removeAttribute(WebCommons.CUSTOMER_NUMBER);
%>

<html>
<head>
<link rel="stylesheet" href="../style/myTemplate/style.css"
	type="text/css">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Employee Menu</title>
</head>
<body>

	<%
		// extract employee's user-name
		String userName = (String) session.getAttribute(WebCommons.USER_NAME);
	%>
	<%--display welcome message	--%>
	<div id="logo">
		<span class="customHeader">Welcome <%=controller.getUserRealName(userName)%>!
		</span>
	</div>

	<%--display menu	--%>
	<div class="post">

		<div id="content">
			<h2 class="title">
				<a>Please select one of the following:</a>
			</h2>
			<br>
			<table>
				<tr>
					<td><span class="customMenuOption">Display all products</span></td>
					<td><a
						href="../transactions/customerTransactions/GetAllProducts.jsp"
						class="myButton">Go!</a></td>
				</tr>
				<tr>
					<td><span class="customMenuOption">Get product price</span></td>
					<td><a
						href="../transactions/customerTransactions/GetProductPrice.jsp"
						class="myButton">Go!</a></td>
				</tr>
				<tr>
					<td><span class="customMenuOption">Create customer
							account</span></td>
					<td><a
						href="../transactions/employeeTransactions/AddNewCustomer.jsp"
						class="myButton">Go!</a></td>
				</tr>
				<tr>
					<td><span class="customMenuOption">Add new product</span></td>
					<td><a
						href="../transactions/employeeTransactions/AddProduct.jsp"
						class="myButton">Go!</a></td>
				</tr>
				<tr>
					<td><span class="customMenuOption">Update product price</span></td>
					<td><a
						href="../transactions/employeeTransactions/UpdateProduct.jsp"
						class="myButton">Go!</a></td>
				</tr>
				<tr>
					<td><span class="customMenuOption">Get orders of
							customer</span></td>
					<td><a
						href="../transactions/employeeTransactions/GetOrders.jsp"
						class="myButton">Go!</a></td>
				</tr>
				<tr>
					<td><span class="customMenuOption">Update customer
							details</span></td>
					<td><a
						href="../transactions/employeeTransactions/UpdateCustomerDetails.jsp"
						class="myButton">Go!</a></td>
				</tr>
				<tr>
					<td><span class="customMenuOption">Make new order</span></td>
					<td><a
						href="../transactions/customerTransactions/MakeOrder.jsp"
						class="myButton">Go!</a></td>
				</tr>				
				<tr>
					<td><span class="customMenuOption">Change your password</span></td>
					<td><a href="../commonPages/ChangePwd.jsp" class="myButton">Go!</a></td>
				</tr>
				<tr>
					<td><span class="customMenuOption">Logout</span></td>
					<td><a href="../Logout.jsp" class="myButton">Go!</a></td>
				</tr>
			</table>		
		</div>

	</div>

</body>
</html>